import { onCleanup, onMount, type Accessor } from "solid-js";

export const GetElementRef = (el: any, accessor: Accessor<any>) => {
  const setRef = accessor();

  onMount(() => setRef(el));
  onCleanup(() => setRef(undefined));
};
